<template>
  <div>
    Parent
    <hr />
    <Child
      name="张文清"
      :age="20"
      :isMan="true"
      :hobby="hobby"
      :address="address"
      @myevent="getValue"
    />
  </div>
</template>

<script setup lang="ts">
import { Person } from '../types/person'
import Child from './02-Child.vue'
import { ref } from 'vue'
const hobby = ref(['学习', '打游戏', '画画'])
const address = ref({
  province: '广西',
  city: '防城港'
})

const getValue = (value: Person) => {
  console.log('---value---', value)
}
</script>
